import request from '@/utils/request'

// 查询房屋信息列表列表
export function listHouses(query) {
  return request({
    url: '/houses/houses/list',
    method: 'get',
    params: query
  })
}

// 查询房屋信息列表详细
export function getHouses(id) {
  return request({
    url: '/houses/houses/' + id,
    method: 'get'
  })
}

// 新增房屋信息列表
export function addHouses(data) {
  return request({
    url: '/houses/houses',
    method: 'post',
    data: data
  })
}

// 修改房屋信息列表
export function updateHouses(data) {
  return request({
    url: '/houses/houses',
    method: 'put',
    data: data
  })
}

// 删除房屋信息列表
export function delHouses(id) {
  return request({
    url: '/houses/houses/' + id,
    method: 'delete'
  })
}


// 租房信息添加
export function addRentHousesService(data) {
  return request({
    url: '/houses/rentHouses/addRentHouses',
    method: 'post',
    data: data
  })
}
